﻿@using res = Resource.Views.Shared.Shared;
@{
    YQBlog.General.GeneralConfigInfo ci = ViewBag.CI as YQBlog.General.GeneralConfigInfo;
    string weblang = Resource.Models.Web.Web.Lang;
    string themepath = string.IsNullOrWhiteSpace(Request.Cookies["web"]["theme"]) ? "~/Content/" : "~/Themes/" + Request.Cookies["web"]["theme"].ToString() + "/Content/";
    Random ran = new Random();
    int RandKey = ran.Next(1, 9);
    string bgurl = themepath.Trim('~') + "image/bg" + RandKey.ToString() + ".jpg";
    string currentTheme = string.IsNullOrWhiteSpace(Request.Cookies["web"]["theme"]) ? "" : Request.Cookies["web"]["theme"].ToString();
}
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8" />
    <title>@ViewBag.Title - @ci.Webtitle</title>
    @RenderSection("Seo", false)
    <link href="@Url.Content(themepath + "css/Site.css")" rel="stylesheet" type="text/css" />
    <link href="@Url.Content("~/Scripts/SyntaxHighlighter/styles/shCoreDefault.css")" rel="stylesheet" type="text/css" />
    <script type="text/javascript">        var defaultLang = '@(ci.DefaultLang)'; var currentTheme = '@(currentTheme)';</script>
    <script src="@Url.Content("~/Scripts/jquery-1.5.1.min.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/modernizr-1.7.min.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery.lazyload.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Content/js/Web.Lang." + @weblang + ".js?v=" + @ci.VersionNo)" type="text/javascript"></script>
    <script src="@Url.Content("~/Content/js/Category.Lang." + @weblang + ".js?v=" + @ci.VersionNo)" type="text/javascript"></script>
    <script src="@Url.Content("~/Content/js/Category.js?v=" + @ci.VersionNo)" type="text/javascript"></script>
    <script src="@Url.Content("~/Content/js/Blog.js?v=" + @ci.VersionNo)" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/SyntaxHighlighter/scripts/shCore.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/SyntaxHighlighter/scripts/shBrush.js")" type="text/javascript"></script>
    @RenderSection("Css", false)
</head>
<body>
<div id="header_wrap">
    <div id="header" style="background-image:url(@bgurl);">
    	<div class="logobg">@ci.Webtitle</div>
        <a class="logo" href="/">@ci.Webtitle</a>
    	<div class="top_navigation" id="logindisplay">@Html.Partial("_LogOnPartial")</div>
        <div class="menu" id="navigation"></div>
        <div class="search_form">                    
            <input type="text" name="searchkey" value="@res.Search" onblur="if(this.value.length == 0) this.value='@res.Search';" onclick="if(this.value == '@res.Search') this.value='';" id="searchkey"/>
            <input type="button" value="Search" class="search_button"/>
        </div>
    </div>
</div>
<script type="text/javascript">
    ViewNav(0, 0);
</script>
<div id="content_wrap">
    <div id="content" class="clearfix">
        @RenderBody()
    </div>
</div>
<div id="footer_wrap">
    <div id="footer">
        <div class="footer_inner">
            @Html.Raw(ci.CopyRight) &nbsp; CopyRight 2012 <a href="@ci.Weburl">@ci.Webtitle</a>
        </div>
    </div>
</div>
</body>
@RenderSection("Js", false)
</html>
<!--Default-->